home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 17 / CU Amiga Magazine's Super CD-ROM 17 (1997)(EMAP Images)(GB)[!][issue 1997-12].iso / CUCD / Programming / DiceSource / src / editors / DME / rexx / DME_ErrorParse.rexx < prev    next >
OS/2 REXX Batch file  |  1995-12-24  |  1KB  |  59 lines

  1. /*
  2. **    $Id: DME_ErrorParse.rexx,v 30.0 1994/06/10 18:06:11 dice Exp $
  3. **
  4. **    DICEHelp help system.  Script for DME
  5. **
  6. **    Rexx script modeled after version by David Joiner
  7. **
  8. **  Notes: This assumes that your DCC:Config/DCC.Config file contains the
  9. **       following line:
  10. **  cmd= rx DCC:Rexx/DME_ErrorParse.rexx %e "%c" "%f" "%0"
  11. */
  12.  
  13. OPTIONS RESULTS
  14.  
  15. PARSE ARG EFile '"' Fn '" "' CurDir '" "' CFile '" "' VPort '"'
  16.  
  17. say "TEST"
  18.  
  19. portname = 'DICE_ERROR_PARSER'  /* DICEHelp's port name */
  20.  
  21. if ~show('p',portname) then
  22.    do
  23.       address COMMAND 'RUN >NIL: <NIL: DError REXXSTARTUP'
  24.  
  25.       do i = 1 to 6
  26.      if ~show('p',portname) then
  27.         address COMMAND 'wait 1'
  28.       end
  29.  
  30.       if ~show('p',portname) then
  31.      do
  32.         say "Dice Error Parser (DERROR) program not found!"
  33.         address COMMAND 'type' EFile
  34.         exit
  35.      end
  36.    end
  37.  
  38. /**
  39.  ** Get the error messages loaded in.
  40.  ** This will return a list of lines within the file that have
  41.  ** errors associated with them (if any)
  42.  **/
  43. ADDRESS DICE_ERROR_PARSER LOAD EFile '"'CurDir'" "'Fn'" "'VPort'"'
  44. LINES = RESULT
  45. ADDRESS COMMAND 'Delete' EFile
  46.  
  47. /*
  48.  * Start DME if it is not already running
  49.  */
  50.  
  51. IF ~show('p','DME.01') THEN
  52.     DO
  53.     address COMMAND 'RUN >NIL: <NIL: DME'
  54.     address COMMAND 'Wait 5'
  55.     END
  56.  
  57. ADDRESS DME.01 title "( Hit F7 for first error, F8 for next )"
  58.  
  59.